<?xml version="1.0" encoding="UTF-8" ?>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ include file="/common/base.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Insert title here</title>
<link href="${ctsCss}/table.css" rel="stylesheet" type="text/css" />
</head>
<body>
<%@ include file="/common/message-save.jsp" %>
<form id="dataSet-form" class="form-horizontal" action="${ctx}/set/<c:choose><c:when test="${dataSet.id == null}">insert</c:when><c:otherwise>update</c:otherwise></c:choose>" method="post">
	<input type="hidden" id="id" name="id" value="${dataSet.id}"/>
<table>
	 <tr class="tab_grey">
      <td width="15%">表名：</td>
      <td width="35%"><input type="text" id="tableName" name="tableName" value="${dataSet.tableName }" required maxlength="100" style="width:150px" /></td>
      
     </tr>
     <tr class="tab_grey">
     	<td width="15%">中文表名：</td>
     	<td width="35%"><input type="text" id="chineseName" name="chineseName" value="${dataSet.chineseName }" required maxlength="100" style="width:150px" /></td>
     </tr>
     <tr class="tab_grey">
     	<td width="15%">表类型：</td>
     	<td width="35%">
     		<select id="tableType" name="tableType" required>
				   <option value="">请选择..</option>
				   <option value=1 ${dataSet.tableType==1?'selected':''}>表</option>
				   <option value=0 ${dataSet.tableType==0?'selected':''}>视图</option>	   
			</select>
     	</td>
     </tr>
     
</table>
<div  style="text-align: center;">
	<button type="button" class="btn btn-primary" id="saveBtn" onclick="setSaveInfo();">保存</button>
	<button type="reset" class="btn" id="resetBtn">重置</button>
</div>
</form>
</body>
<script type="text/javascript">
$('#dataSet-form').validate();
function setSaveInfo(){
	$("#dataSet-form").submit();
}
</script>
</html>